# Manhatan drought
library(ggrepel)
library(vegan)
library(dplyr)
rm(list = ls())
load("EPICON.data.preparation.RC.bNTI.ted.2019.04.19.Rdata")
otu_table0<-data.frame(t(fung.raw)) ##Read in the raw data###
row.names(otu_table0)<-row.names(ID)
otu_table1<-data.frame(t(otu_table0[ID$Kingdom=="Fungi",]))
env$Treatment1<-factor(env$Treatment1,levels=c("Control", "Pre_flowering_drought", "Post_flowering_drought"))
manhatan.drought<- function (habitat,tp, Ntreat, treat)
{
fung<-otu_table1[env$Habitat == habitat, ]
fung<-fung[,colSums(fung)>0]
subse<- env$Habitat == habitat & env$TP> tp & env$Treatment1 != Ntreat
fung.subs<-otu_table1[subse,]
set.seed(315)
fung.subs<-data.frame(rrarefy(fung.subs, min(rowSums(fung.subs))))
com<-fung.subs[,colSums(fung.subs)>0]
env.subs<-env[subse,]
va<-env.subs[, treat]
paov<-adonis(com~va)
print(paov)
dvoc<-data.frame()
for (i in c(1: ncol(com)))
{
tt<-t.test(com[,i]~va) # t test
p<-tt$p.value # pvalue of t test
name<-colnames(com)[i] # OTU name
fs<-aggregate(com[,i], by=list(va), FUN=mean) # mean abundance of OTU in two habitats
fc<-log2((fs[1,2]+1)/(fs[2,2]+1))
abu<-log2(colSums(com)[i]/nrow(com)+1)
dd<-data.frame(fc,p, name,abu, i, " ")
dvoc<-rbind(dvoc, dd)
}
dvoc<-data.frame(dvoc)
names(dvoc)<-c("log2FoldChange", "pvalue","name", "log2AverageAbundance", "order", "Group")
dvoc$padj<-p.adjust(dvoc$pvalue, n = length(dvoc$pvalue))
dvoc$neglogp = -log(dvoc$pvalue)
dvoc$level = as.factor(ifelse( dvoc$log2FoldChange > 0, "Control > Drought", "Drought > Control"))
dvoc$level<-factor(dvoc$level,levels=c("Control > Drought","Drought > Control"))
x<-droplevels(merge(dvoc,ID, by.y = "OTU.ID.1", by.x = "name", all = FALSE))
x = arrange(x, Guild,Genus,log2AverageAbundance,neglogp)
x<-x[order(x$Guild),]
x$name = factor(x$name, levels=x$name)
x1<-droplevels(x[x$neglogp >=10,])
pos<-droplevels(x1[x1$log2FoldChange>0,])
neg<-droplevels(x1[x1$log2FoldChange<0,])
print(pos$name)
print(neg$name)
x$Guild<-factor(x$Guild, labels = c("Arbuscular mycorrhiza", "Endophyte", "Plant pathogen", "Plant pathogen (Yeast)", "Saprotroph", "Saprotroph (Yeast)", "Others"))
p1<-ggplot(x, aes(x=name, y=neglogp, color=Guild, size=log2AverageAbundance, shape=level)) +
geom_point(alpha = 0.5, stroke = 1.5) +
geom_text_repel(data=subset(x, neglogp > 10),vjust="inward",hjust="inward",
aes(label=Genus), angle = 0, size=3, color="black",fontface= "bold")+
geom_hline(yintercept= 10, linetype=1, color="green") +
scale_shape_manual(values=c(1, 2))+
scale_size(breaks=c(5, 10, 15)) +
labs(x=" ", y=" ") +
scale_color_manual(values=c("green","blue","purple","black","chocolate", "red","grey"))+
theme(axis.ticks.x=element_blank(),axis.text.x=element_blank())+
theme(panel.background = element_rect(fill = NA)) +
labs(title = habitat, x = "", y=" ", size = "log(Average Abundance)", shape = "Drought effect") +
theme(legend.title = element_text(colour="black", size=15, face="bold"),
legend.text = element_text(colour="black", size=15, face="bold"),
axis.line = element_line(linetype = "solid"),
axis.text=element_text(size=10,face="bold"),
axis.title=element_text(size=15,face="bold"))
return(p1)
}
manhatan.drought("Leaf", 2, "Post_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 0.3085 0.30849 2.037 0.01131 0.09 .
## Residuals 178 26.9564 0.15144 0.98869
## Total 179 27.2649 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## factor(0)
## Levels:
## factor(0)
## Levels:

manhatan.drought("Leaf", 9, "Pre_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 0.28088 0.280882 13.22 0.1233 0.001 ***
## Residuals 94 1.99719 0.021247 0.8767
## Total 95 2.27808 1.0000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## [1] OTU124_Cryptococcus OTU24_Cryptococcus
## [3] OTU282_Cystofilobasidium OTU145_Cryptococcus
## [5] OTU69_Tremellomycetes OTU61_Cryptococcus
## [7] OTU14_Symmetrospora
## 7 Levels: OTU124_Cryptococcus ... OTU14_Symmetrospora
## [1] OTU27_Alternaria OTU53_Stemphylium OTU1_Cladosporium
## Levels: OTU27_Alternaria OTU53_Stemphylium OTU1_Cladosporium

manhatan.drought("Root", 2, "Post_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 5.8758 5.8758 50.313 0.22037 0.001 ***
## Residuals 178 20.7876 0.1168 0.77963
## Total 179 26.6634 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## [1] OTU126_Glomus OTU213_Rhizophagus OTU118_Rhizophagus
## [4] OTU106_Sordariomycetes OTU322_Fusarium OTU32_Fusarium
## [7] OTU16_Fusarium OTU18_Gibberella OTU19_Sarocladium
## [10] OTU2_Setophoma OTU136_Auriculariales OTU110_Myrmecridium
## [13] OTU35_Myrothecium OTU197_Fungi OTU535_Pezizaceae
## [16] OTU151_Vermispora
## 16 Levels: OTU126_Glomus OTU213_Rhizophagus ... OTU151_Vermispora
## [1] OTU5_Acremonium OTU22_Periconia OTU105_Aspergillus
## [4] OTU109_Beauveria OTU97_Penicillium OTU221_Spiromastix
## [7] OTU102_Arthropsis OTU212_Sordariomycetes
## 8 Levels: OTU5_Acremonium OTU22_Periconia ... OTU212_Sordariomycetes

manhatan.drought("Root", 9, "Pre_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 1.1177 1.11771 19.501 0.17181 0.001 ***
## Residuals 94 5.3876 0.05732 0.82819
## Total 95 6.5053 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## [1] OTU229_Glomus OTU126_Glomus OTU133_Glomus
## [4] OTU213_Rhizophagus OTU132_Rhizophagus OTU161_Rhizophagus
## [7] OTU118_Rhizophagus OTU150_Rhizophagus OTU166_Rhizophagus
## [10] OTU106_Sordariomycetes OTU182_Ascomycota OTU123_Hypocreales
## [13] OTU60_Hypocreales OTU153_Auriculariales OTU136_Auriculariales
## [16] OTU1_Cladosporium OTU319_Entoloma OTU110_Myrmecridium
## [19] OTU56_Agaricomycetes OTU55_Panaeolus OTU23_Stachybotrys
## [22] OTU535_Pezizaceae
## 22 Levels: OTU229_Glomus OTU126_Glomus ... OTU535_Pezizaceae
## [1] OTU16_Fusarium OTU486_Fungi
## Levels: OTU16_Fusarium OTU486_Fungi

manhatan.drought("Rhizosphere", 2, "Post_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 3.600 3.6001 22.299 0.11133 0.001 ***
## Residuals 178 28.738 0.1614 0.88867
## Total 179 32.338 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## [1] OTU408_Fungi OTU106_Sordariomycetes OTU322_Fusarium
## [4] OTU41_Fusarium OTU32_Fusarium OTU16_Fusarium
## [7] OTU6_Fusarium OTU18_Gibberella OTU19_Sarocladium
## [10] OTU136_Auriculariales OTU83_Cladosporium OTU35_Myrothecium
## [13] OTU151_Vermispora
## 13 Levels: OTU408_Fungi OTU106_Sordariomycetes ... OTU151_Vermispora
## [1] OTU5_Acremonium OTU105_Aspergillus OTU109_Beauveria
## [4] OTU97_Penicillium OTU221_Spiromastix
## 5 Levels: OTU5_Acremonium OTU105_Aspergillus ... OTU221_Spiromastix

manhatan.drought("Rhizosphere", 9, "Pre_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 2.9507 2.95074 31.243 0.24946 0.001 ***
## Residuals 94 8.8779 0.09445 0.75054
## Total 95 11.8286 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## [1] OTU106_Sordariomycetes OTU27_Alternaria OTU4_Alternaria
## [4] OTU11_Epicoccum OTU136_Auriculariales OTU83_Cladosporium
## [7] OTU1_Cladosporium OTU319_Entoloma OTU24_Cryptococcus
## [10] OTU10_Filobasidium OTU69_Tremellomycetes OTU90_Rhodotorula
## [13] OTU26_Sporobolomyces OTU14_Symmetrospora
## 14 Levels: OTU106_Sordariomycetes OTU27_Alternaria ... OTU14_Symmetrospora
## [1] OTU5_Acremonium OTU32_Fusarium OTU16_Fusarium OTU18_Gibberella
## [5] OTU19_Sarocladium OTU2_Setophoma OTU137_Eurotiales OTU97_Penicillium
## [9] OTU197_Fungi
## 9 Levels: OTU5_Acremonium OTU32_Fusarium ... OTU197_Fungi

manhatan.drought("Soil", 2, "Post_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 0.716 0.71604 6.2538 0.03394 0.001 ***
## Residuals 178 20.380 0.11450 0.96606
## Total 179 21.096 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## [1] OTU133_Glomus OTU277_Glomus OTU224_Glomus OTU206_Glomus
## Levels: OTU133_Glomus OTU277_Glomus OTU224_Glomus OTU206_Glomus
## [1] OTU51_Rhizophagus OTU5_Acremonium OTU17_Acrophialophora
## [4] OTU59_Chaetomium
## 4 Levels: OTU51_Rhizophagus OTU5_Acremonium ... OTU59_Chaetomium

manhatan.drought("Soil", 9, "Pre_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 0.4653 0.46534 4.4612 0.04531 0.001 ***
## Residuals 94 9.8050 0.10431 0.95469
## Total 95 10.2703 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## factor(0)
## Levels:
## [1] OTU17_Acrophialophora OTU97_Penicillium
## Levels: OTU17_Acrophialophora OTU97_Penicillium

manhatan.drought<- function (habitat,tp, Ntreat, treat)
{
fung<-otu_table1[env$Habitat == habitat, ]
fung<-fung[,colSums(fung)>0]
subse<- env$Habitat == habitat & env$TP> tp & env$Treatment1 != Ntreat
fung.subs<-otu_table1[subse,]
set.seed(315)
fung.subs<-data.frame(rrarefy(fung.subs, min(rowSums(fung.subs))))
com<-fung.subs[,colSums(fung.subs)>0]
env.subs<-env[subse,]
va<-env.subs[, treat]
paov<-adonis(com~va)
print(paov)
dvoc<-data.frame()
for (i in c(1: ncol(com)))
{
tt<-t.test(com[,i]~va) # t test
p<-tt$p.value # pvalue of t test
name<-colnames(com)[i] # OTU name
fs<-aggregate(com[,i], by=list(va), FUN=mean) # mean abundance of OTU in two habitats
fc<-log2((fs[1,2]+1)/(fs[2,2]+1))
abu<-log2(colSums(com)[i]/nrow(com)+1)
dd<-data.frame(fc,p, name,abu, i, " ")
dvoc<-rbind(dvoc, dd)
}
dvoc<-data.frame(dvoc)
names(dvoc)<-c("log2FoldChange", "pvalue","name", "log2AverageAbundance", "order", "Group")
dvoc$padj<-p.adjust(dvoc$pvalue, n = length(dvoc$pvalue))
dvoc$neglogp = -log(dvoc$pvalue)
dvoc$level = as.factor(ifelse( dvoc$log2FoldChange > 0, "Control > Drought", "Drought > Control"))
dvoc$level<-factor(dvoc$level,levels=c("Control > Drought","Drought > Control"))
x<-droplevels(merge(dvoc,ID, by.y = "OTU.ID.1", by.x = "name", all = FALSE))
x = arrange(x, Guild,Genus,log2AverageAbundance,neglogp)
x<-x[order(x$Guild),]
x$name = factor(x$name, levels=x$name)
x1<-droplevels(x[x$neglogp >=10,])
pos<-droplevels(x1[x1$log2FoldChange>0,])
neg<-droplevels(x1[x1$log2FoldChange<0,])
print(pos$name)
print(neg$name)
x$Guild<-factor(x$Guild, labels = c("Arbuscular mycorrhiza", "Endophyte", "Plant pathogen", "Plant pathogen (Yeast)", "Saprotroph", "Saprotroph (Yeast)", "Others"))
p1<-ggplot(x, aes(x=name, y=neglogp, color=Guild, size=log2AverageAbundance, shape=level)) +
geom_point(alpha = 0.5, stroke = 1.5) +
#geom_text_repel(data=subset(x, neglogp > 10),vjust="inward",hjust="inward",
# aes(label=Genus), angle = 0, size=3, color="black",fontface= "bold")+
geom_hline(yintercept= 10, linetype=1, color="green") +
scale_shape_manual(values=c(1, 2))+
scale_size(breaks=c(5, 10, 15)) +
labs(x=" ", y=" ") +
scale_color_manual(values=c("green","blue","purple","black","chocolate", "red","grey"))+
theme(axis.ticks.x=element_blank(),axis.text.x=element_blank())+
theme(panel.background = element_rect(fill = NA),legend.position = "none") +
labs(title = habitat, x = "", y=" ", size = "log(Average Abundance)", shape = "Drought effect") +
theme(legend.title = element_text(colour="black", size=15, face="bold"),
legend.text = element_text(colour="black", size=15, face="bold"),
axis.line = element_line(linetype = "solid"),
axis.text=element_text(size=10,face="bold"),
axis.title=element_text(size=15,face="bold"))
return(p1)
}
manhatan.drought("Leaf", 2, "Post_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 0.3085 0.30849 2.037 0.01131 0.09 .
## Residuals 178 26.9564 0.15144 0.98869
## Total 179 27.2649 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## factor(0)
## Levels:
## factor(0)
## Levels:

manhatan.drought("Leaf", 9, "Pre_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 0.28088 0.280882 13.22 0.1233 0.001 ***
## Residuals 94 1.99719 0.021247 0.8767
## Total 95 2.27808 1.0000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## [1] OTU124_Cryptococcus OTU24_Cryptococcus
## [3] OTU282_Cystofilobasidium OTU145_Cryptococcus
## [5] OTU69_Tremellomycetes OTU61_Cryptococcus
## [7] OTU14_Symmetrospora
## 7 Levels: OTU124_Cryptococcus ... OTU14_Symmetrospora
## [1] OTU27_Alternaria OTU53_Stemphylium OTU1_Cladosporium
## Levels: OTU27_Alternaria OTU53_Stemphylium OTU1_Cladosporium

manhatan.drought("Root", 2, "Post_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 5.8758 5.8758 50.313 0.22037 0.001 ***
## Residuals 178 20.7876 0.1168 0.77963
## Total 179 26.6634 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## [1] OTU126_Glomus OTU213_Rhizophagus OTU118_Rhizophagus
## [4] OTU106_Sordariomycetes OTU322_Fusarium OTU32_Fusarium
## [7] OTU16_Fusarium OTU18_Gibberella OTU19_Sarocladium
## [10] OTU2_Setophoma OTU136_Auriculariales OTU110_Myrmecridium
## [13] OTU35_Myrothecium OTU197_Fungi OTU535_Pezizaceae
## [16] OTU151_Vermispora
## 16 Levels: OTU126_Glomus OTU213_Rhizophagus ... OTU151_Vermispora
## [1] OTU5_Acremonium OTU22_Periconia OTU105_Aspergillus
## [4] OTU109_Beauveria OTU97_Penicillium OTU221_Spiromastix
## [7] OTU102_Arthropsis OTU212_Sordariomycetes
## 8 Levels: OTU5_Acremonium OTU22_Periconia ... OTU212_Sordariomycetes

manhatan.drought("Root", 9, "Pre_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 1.1177 1.11771 19.501 0.17181 0.001 ***
## Residuals 94 5.3876 0.05732 0.82819
## Total 95 6.5053 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## [1] OTU229_Glomus OTU126_Glomus OTU133_Glomus
## [4] OTU213_Rhizophagus OTU132_Rhizophagus OTU161_Rhizophagus
## [7] OTU118_Rhizophagus OTU150_Rhizophagus OTU166_Rhizophagus
## [10] OTU106_Sordariomycetes OTU182_Ascomycota OTU123_Hypocreales
## [13] OTU60_Hypocreales OTU153_Auriculariales OTU136_Auriculariales
## [16] OTU1_Cladosporium OTU319_Entoloma OTU110_Myrmecridium
## [19] OTU56_Agaricomycetes OTU55_Panaeolus OTU23_Stachybotrys
## [22] OTU535_Pezizaceae
## 22 Levels: OTU229_Glomus OTU126_Glomus ... OTU535_Pezizaceae
## [1] OTU16_Fusarium OTU486_Fungi
## Levels: OTU16_Fusarium OTU486_Fungi

manhatan.drought("Rhizosphere", 2, "Post_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 3.600 3.6001 22.299 0.11133 0.001 ***
## Residuals 178 28.738 0.1614 0.88867
## Total 179 32.338 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## [1] OTU408_Fungi OTU106_Sordariomycetes OTU322_Fusarium
## [4] OTU41_Fusarium OTU32_Fusarium OTU16_Fusarium
## [7] OTU6_Fusarium OTU18_Gibberella OTU19_Sarocladium
## [10] OTU136_Auriculariales OTU83_Cladosporium OTU35_Myrothecium
## [13] OTU151_Vermispora
## 13 Levels: OTU408_Fungi OTU106_Sordariomycetes ... OTU151_Vermispora
## [1] OTU5_Acremonium OTU105_Aspergillus OTU109_Beauveria
## [4] OTU97_Penicillium OTU221_Spiromastix
## 5 Levels: OTU5_Acremonium OTU105_Aspergillus ... OTU221_Spiromastix

manhatan.drought("Rhizosphere", 9, "Pre_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 2.9507 2.95074 31.243 0.24946 0.001 ***
## Residuals 94 8.8779 0.09445 0.75054
## Total 95 11.8286 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## [1] OTU106_Sordariomycetes OTU27_Alternaria OTU4_Alternaria
## [4] OTU11_Epicoccum OTU136_Auriculariales OTU83_Cladosporium
## [7] OTU1_Cladosporium OTU319_Entoloma OTU24_Cryptococcus
## [10] OTU10_Filobasidium OTU69_Tremellomycetes OTU90_Rhodotorula
## [13] OTU26_Sporobolomyces OTU14_Symmetrospora
## 14 Levels: OTU106_Sordariomycetes OTU27_Alternaria ... OTU14_Symmetrospora
## [1] OTU5_Acremonium OTU32_Fusarium OTU16_Fusarium OTU18_Gibberella
## [5] OTU19_Sarocladium OTU2_Setophoma OTU137_Eurotiales OTU97_Penicillium
## [9] OTU197_Fungi
## 9 Levels: OTU5_Acremonium OTU32_Fusarium ... OTU197_Fungi

manhatan.drought("Soil", 2, "Post_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 0.716 0.71604 6.2538 0.03394 0.001 ***
## Residuals 178 20.380 0.11450 0.96606
## Total 179 21.096 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## [1] OTU133_Glomus OTU277_Glomus OTU224_Glomus OTU206_Glomus
## Levels: OTU133_Glomus OTU277_Glomus OTU224_Glomus OTU206_Glomus
## [1] OTU51_Rhizophagus OTU5_Acremonium OTU17_Acrophialophora
## [4] OTU59_Chaetomium
## 4 Levels: OTU51_Rhizophagus OTU5_Acremonium ... OTU59_Chaetomium

manhatan.drought("Soil", 9, "Pre_flowering_drought","Treatment1" )
##
## Call:
## adonis(formula = com ~ va)
##
## Permutation: free
## Number of permutations: 999
##
## Terms added sequentially (first to last)
##
## Df SumsOfSqs MeanSqs F.Model R2 Pr(>F)
## va 1 0.4653 0.46534 4.4612 0.04531 0.001 ***
## Residuals 94 9.8050 0.10431 0.95469
## Total 95 10.2703 1.00000
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## factor(0)
## Levels:
## [1] OTU17_Acrophialophora OTU97_Penicillium
## Levels: OTU17_Acrophialophora OTU97_Penicillium
